package com.sf.fy.uav.common.enums;

import lombok.Getter;

/**
 * @author ta136817
 */
public enum DeliveryMethodEnum {
    /**
     * 优惠券状态枚举
     */
    UAV("无人机配送", (byte) 0);


    private final String desc;
    private Byte value;

    public String getDesc() {
        return desc;
    }

    public Byte getValue() {
        return value;
    }

    public void setValue(Byte value) {
        this.value = value;
    }

    DeliveryMethodEnum(String desc, Byte value) {
        this.desc = desc;
        this.value = value;
    }

    public static String getDesc(Byte value) {
        for (DeliveryMethodEnum ele : values()) {
            if (ele.getValue().equals(value)) {
                return ele.getDesc();
            }
        }
        return null;
    }
}
